gtk4.git
9 years agoDocument ::snapshot vfunc
Matthias Clasen [Sat, 19 Nov 2016 17:37:19 +0000 (12:37 -0500)]
Document ::snapshot vfunc

9 years agoDrop macro wrappers for get_version functions
Matthias Clasen [Sat, 19 Nov 2016 17:27:57 +0000 (12:27 -0500)]
Drop macro wrappers for get_version functions

These are not really useful, and were added long ago
as a clutch for transitioning to the new names.

9 years agotestgtk: Stop using gtk_micro_version
Matthias Clasen [Sat, 19 Nov 2016 17:27:02 +0000 (12:27 -0500)]
testgtk: Stop using gtk_micro_version

This will be going away soon

9 years agoFix a signature mismatch
Matthias Clasen [Sat, 19 Nov 2016 17:26:40 +0000 (12:26 -0500)]
Fix a signature mismatch

The new drawingarea draw func returns void.

9 years agowidgetnode: We never need widget paths anymore
Benjamin Otte [Sat, 19 Nov 2016 17:06:50 +0000 (18:06 +0100)]
widgetnode: We never need widget paths anymore

Backwards compat is not necessary in GTK4.

9 years agoRemove once again, empty doc comments that break the docs
Matthias Clasen [Sat, 19 Nov 2016 16:54:24 +0000 (11:54 -0500)]
Remove once again, empty doc comments that break the docs

This is just more breakage from introspection ursurping doc
comments. Somebody needs to find a proper solution before this
is brought back.

9 years agoUpdated Danish translation
Ask Hjorth Larsen [Sat, 19 Nov 2016 15:29:25 +0000 (16:29 +0100)]
Updated Danish translation

9 years agoReduce the text shadow warnings
Matthias Clasen [Sat, 19 Nov 2016 13:05:42 +0000 (08:05 -0500)]
Reduce the text shadow warnings

They make it hard to see other useful information.

9 years agoUpdate Kazakh translation
Baurzhan Muftakhidinov [Sat, 19 Nov 2016 12:15:59 +0000 (12:15 +0000)]
Update Kazakh translation
(cherry picked from commit 4bc2904daea70128717e6713bec6c7f8d162d12f)

9 years agorender: Compute extents correctly
Benjamin Otte [Sat, 19 Nov 2016 02:15:51 +0000 (03:15 +0100)]
render: Compute extents correctly

I multiplied matrices the wrong way. Again.

9 years agotests: Remove styleexamples test
Benjamin Otte [Fri, 18 Nov 2016 23:28:53 +0000 (00:28 +0100)]
tests: Remove styleexamples test

It's so outdated it doesn't even do anything useful anymore.

So I'll just assume nobody uses it.

9 years agoprogressbar: add empty and full classes on trough based on fill-level
Simon Steinbeiss [Fri, 18 Nov 2016 22:43:09 +0000 (23:43 +0100)]
progressbar: add empty and full classes on trough based on fill-level

Pointed out in https://bugzilla.gnome.org/show_bug.cgi?id=774695

9 years agotests: Use new drawing area APIs in testcairo
Benjamin Otte [Fri, 18 Nov 2016 21:41:15 +0000 (22:41 +0100)]
tests: Use new drawing area APIs in testcairo

9 years agotests: Use drawing area in testellipsise
Benjamin Otte [Fri, 18 Nov 2016 21:37:41 +0000 (22:37 +0100)]
tests: Use drawing area in testellipsise

9 years agotests: Use new drawing area APIs
Benjamin Otte [Fri, 18 Nov 2016 21:27:02 +0000 (22:27 +0100)]
tests: Use new drawing area APIs

9 years agoinspector: Show render node properties
Matthias Clasen [Sat, 19 Nov 2016 01:59:10 +0000 (20:59 -0500)]
inspector: Show render node properties

9 years agoDocument newly supported 3d transforms in CSS
Matthias Clasen [Sat, 19 Nov 2016 00:34:02 +0000 (19:34 -0500)]
Document newly supported 3d transforms in CSS

9 years agoMore docs cleanup
Matthias Clasen [Fri, 18 Nov 2016 23:54:35 +0000 (18:54 -0500)]
More docs cleanup

9 years agocsstransform: Handle matrix3d()
Benjamin Otte [Fri, 18 Nov 2016 20:43:18 +0000 (21:43 +0100)]
csstransform: Handle matrix3d()

9 years agocsstransform: Implement 3D scale and transform matrices
Benjamin Otte [Fri, 18 Nov 2016 20:02:52 +0000 (21:02 +0100)]
csstransform: Implement 3D scale and transform matrices

9 years agocsstransforms: Parse 3D rotations
Benjamin Otte [Fri, 18 Nov 2016 19:21:06 +0000 (20:21 +0100)]
csstransforms: Parse 3D rotations

9 years agocsstransform: Convert to use graphene_matrix_t
Benjamin Otte [Fri, 18 Nov 2016 15:01:56 +0000 (16:01 +0100)]
csstransform: Convert to use graphene_matrix_t

Pre-work to use 3D-transforms.

9 years agotests: Use a drawing area in motion-compression example
Benjamin Otte [Fri, 18 Nov 2016 14:09:36 +0000 (15:09 +0100)]
tests: Use a drawing area in motion-compression example

9 years agotests: Use a drawing area in animated-resizing
Benjamin Otte [Fri, 18 Nov 2016 14:02:49 +0000 (15:02 +0100)]
tests: Use a drawing area in animated-resizing

9 years agoWork towards a clean docs build
Matthias Clasen [Fri, 18 Nov 2016 19:43:34 +0000 (14:43 -0500)]
Work towards a clean docs build

Remove various no-longer-existing functions from the sections
file, and exclude more private headers, etc.

9 years agoRename broadwayd to gtk4-broadwayd
Matthias Clasen [Fri, 18 Nov 2016 18:40:37 +0000 (13:40 -0500)]
Rename broadwayd to gtk4-broadwayd

This was the last unprefixed binary, and it was causing file
conflicts between gtk3 and gtk4.

9 years agogdkwindow: Allow native subsurface for all parents
Olivier Fourdan [Tue, 15 Nov 2016 13:49:03 +0000 (14:49 +0100)]
gdkwindow: Allow native subsurface for all parents

Under Wayland, a subsurface can have another surface as parent, but
gdk would not allow native windows if the parent is not the root window.

Allow native subsurface for all parent under Wayland, not just for the
root window.

https://bugzilla.gnome.org/show_bug.cgi?id=774475

9 years agowayland: Keep last scale factor on surfaces after it left all outputs
Carlos Garnacho [Tue, 15 Nov 2016 14:07:39 +0000 (15:07 +0100)]
wayland: Keep last scale factor on surfaces after it left all outputs

This can be triggered on workspace switches, and on hidpi results in
the scale factor being reset to 1 while the window is not in the
current workspace.

https://bugzilla.gnome.org/show_bug.cgi?id=774476

9 years agodocs: Name the 3.90 index properly
Matthias Clasen [Fri, 18 Nov 2016 13:14:23 +0000 (08:14 -0500)]
docs: Name the 3.90 index properly

9 years agodocs: Ignore gtksnapshotprivate.h
Matthias Clasen [Fri, 18 Nov 2016 13:10:01 +0000 (08:10 -0500)]
docs: Ignore gtksnapshotprivate.h

9 years agosnapshot: Name api parameters consistently
Matthias Clasen [Fri, 18 Nov 2016 12:57:10 +0000 (07:57 -0500)]
snapshot: Name api parameters consistently

gtk-doc gets upset otherwise.

9 years agoDocument GtkSnapshot
Matthias Clasen [Fri, 18 Nov 2016 11:53:57 +0000 (06:53 -0500)]
Document GtkSnapshot

This is just some initial documentation, more detail needed.

9 years agoAdd some drawing information the migration guide
Matthias Clasen [Fri, 18 Nov 2016 12:42:49 +0000 (07:42 -0500)]
Add some drawing information the migration guide

Mention snapshot(), and the new GtkDrawingArea API.

9 years agodocs: Add GtkDrawingAreaDrawFunc
Matthias Clasen [Fri, 18 Nov 2016 11:09:46 +0000 (06:09 -0500)]
docs: Add GtkDrawingAreaDrawFunc

9 years agotests: Use a drawing area in testpopup
Benjamin Otte [Fri, 18 Nov 2016 06:24:31 +0000 (07:24 +0100)]
tests: Use a drawing area in testpopup

9 years agotests: Make testtooltips not use the draw signal
Benjamin Otte [Fri, 18 Nov 2016 06:22:02 +0000 (07:22 +0100)]
tests: Make testtooltips not use the draw signal

9 years agotests: Produce load without waiting for draw signal
Benjamin Otte [Fri, 18 Nov 2016 06:15:12 +0000 (07:15 +0100)]
tests: Produce load without waiting for draw signal

9 years agotests: Use drawing area instead of draw signal
Benjamin Otte [Fri, 18 Nov 2016 06:14:28 +0000 (07:14 +0100)]
tests: Use drawing area instead of draw signal

9 years agotestsuite: Don't use draw signal, use a drawing area instead
Benjamin Otte [Fri, 18 Nov 2016 05:37:33 +0000 (06:37 +0100)]
testsuite: Don't use draw signal, use a drawing area instead

9 years agoprintunixdialog: Use new drawing area API
Benjamin Otte [Fri, 18 Nov 2016 05:32:27 +0000 (06:32 +0100)]
printunixdialog: Use new drawing area API

9 years agocoloreditor: Don't draw a background on boxes
Benjamin Otte [Fri, 18 Nov 2016 05:19:27 +0000 (06:19 +0100)]
coloreditor: Don't draw a background on boxes

Boxes know how to draw backgrounds these days.

9 years agogtk-demo: Update drawing area usage to new APIs
Benjamin Otte [Fri, 18 Nov 2016 05:16:38 +0000 (06:16 +0100)]
gtk-demo: Update drawing area usage to new APIs

A few demos are broken because they do input on drawing areas.

9 years agodrawingarea: Add gtk_drawing_area_set_draw_func()
Benjamin Otte [Fri, 18 Nov 2016 04:45:36 +0000 (05:45 +0100)]
drawingarea: Add gtk_drawing_area_set_draw_func()

9 years agodrawingarea: Add content-width and content-height properties
Benjamin Otte [Fri, 18 Nov 2016 03:00:02 +0000 (04:00 +0100)]
drawingarea: Add content-width and content-height properties

People should use these instead of gtk_widget_set_size_request().

9 years agodrawingarea: Clean up
Benjamin Otte [Fri, 18 Nov 2016 01:35:05 +0000 (02:35 +0100)]
drawingarea: Clean up

No need to send configure events anymore and this should be a no-window
widget.

9 years agogsk: Don't leak texture surfaces
Matthias Clasen [Fri, 18 Nov 2016 01:29:07 +0000 (20:29 -0500)]
gsk: Don't leak texture surfaces

gsk_texture_download returns a reference.

9 years agostyle context: Don't leak a widget path
Matthias Clasen [Fri, 18 Nov 2016 01:22:42 +0000 (20:22 -0500)]
style context: Don't leak a widget path

Found by valgrind.

9 years agowidget: Add a defualt snapshot vfunc
Benjamin Otte [Thu, 17 Nov 2016 23:46:49 +0000 (00:46 +0100)]
widget: Add a defualt snapshot vfunc

Just to avoid having to do NULL checks when calling
widget_class->snapshot. We were crashing with drawing areas who don't
have a draw or a snapshot vfunc (woot!).

9 years agoUpdated Czech translation
Marek Černocký [Thu, 17 Nov 2016 23:40:11 +0000 (00:40 +0100)]
Updated Czech translation

9 years agowidget: Fix math screwups in clip calculation
Benjamin Otte [Thu, 17 Nov 2016 22:16:14 +0000 (23:16 +0100)]
widget: Fix math screwups in clip calculation

We need so subtract the allocation from the clip to get the clip offset,
not the other way around.

This was screwing in particular with marks on GtkScale, because GtkScale
mark clip computation is broken and always returns (0,0) which makes
scales have a waaaaay too large clip.
But that's another bug.

9 years agogdk: Fix a variable
Benjamin Otte [Thu, 17 Nov 2016 21:03:04 +0000 (22:03 +0100)]
gdk: Fix a variable

The passed in surface is the current_paint surface, so I guess this
usage hasn't been noticed.

9 years agoplaceview: Don't leak the file enumerator
Matthias Clasen [Thu, 17 Nov 2016 18:50:25 +0000 (13:50 -0500)]
placeview: Don't leak the file enumerator

Pointed out in https://bugzilla.gnome.org/show_bug.cgi?id=774634

9 years agoentry: Fix input window position for icons
Matthias Clasen [Thu, 17 Nov 2016 17:04:35 +0000 (12:04 -0500)]
entry: Fix input window position for icons

This makes the icon in the placesview address entry and
in widget-factory's progress entry work again.

9 years agotests/styleexamples: Remove gtk_render_extension calls
Timm Bäder [Thu, 17 Nov 2016 15:45:10 +0000 (16:45 +0100)]
tests/styleexamples: Remove gtk_render_extension calls

The function doesn't exist anymore so there's nothing to test.

9 years agofilechooserwidget: Forward file filter to entry
Timm Bäder [Tue, 15 Nov 2016 09:51:41 +0000 (10:51 +0100)]
filechooserwidget: Forward file filter to entry

And in the entry, apply the currently used filter as a second step to
the completion items.

https://bugzilla.gnome.org/show_bug.cgi?id=773007

9 years agosizerequest: rename _compute_size_for_orientation to _measure
Timm Bäder [Sat, 12 Nov 2016 21:15:48 +0000 (22:15 +0100)]
sizerequest: rename _compute_size_for_orientation to _measure

They have the exact same parameters and gtk_widget_measure did
unnecessary work before. Also better stack traces!

9 years agodocs: Fix print-related includes
Matthias Clasen [Thu, 17 Nov 2016 14:33:16 +0000 (09:33 -0500)]
docs: Fix print-related includes

Pointed out in https://bugzilla.gnome.org/show_bug.cgi?id=774614.

9 years agoGtkFileChooser: Make local-only default to FALSE
Matthias Clasen [Thu, 17 Nov 2016 14:06:57 +0000 (09:06 -0500)]
GtkFileChooser: Make local-only default to FALSE

There is no good reason anymore to default to TRUE, and this
default only makes applications miss out on useful functionality.

9 years agoRevert "GtkFileChooser: Make local-only default to FALSE"
Matthias Clasen [Thu, 17 Nov 2016 14:05:47 +0000 (09:05 -0500)]
Revert "GtkFileChooser: Make local-only default to FALSE"

This reverts commit 0bc79910e03b69279d0aee8edf76ae5cae63ff65.

9 years agoGtkFileChooser: Make local-only default to FALSE
Matthias Clasen [Thu, 17 Nov 2016 14:02:29 +0000 (09:02 -0500)]
GtkFileChooser: Make local-only default to FALSE

There is no good reason anymore to default to TRUE, and this
default only makes applications miss out on useful functionality.

9 years agogtk-demo: Set local-only to FALSE for the file chooser
Matthias Clasen [Thu, 17 Nov 2016 13:51:16 +0000 (08:51 -0500)]
gtk-demo: Set local-only to FALSE for the file chooser

No good reason for that.

9 years agogtkplacesview: Add example of IPv6 address in guidance
Ondrej Holy [Wed, 16 Nov 2016 08:03:42 +0000 (09:03 +0100)]
gtkplacesview: Add example of IPv6 address in guidance

Square brackets are mandatory for IPv6 addresses. Add example of IPv6
address in the guidance to make it obvious.

https://bugzilla.gnome.org/show_bug.cgi?id=756570

9 years agodocs: Update an example
Matthias Clasen [Thu, 17 Nov 2016 11:17:11 +0000 (06:17 -0500)]
docs: Update an example

Pointed out in https://bugzilla.gnome.org/show_bug.cgi?id=774490

9 years agospin entry should be a child of spin context
Caolán McNamara [Thu, 17 Nov 2016 10:04:29 +0000 (10:04 +0000)]
spin entry should be a child of spin context

https://bugzilla.gnome.org/show_bug.cgi?id=774609

9 years agoUpdate Brazilian Portuguese translation
Rafael Fontenelle [Thu, 17 Nov 2016 04:21:21 +0000 (04:21 +0000)]
Update Brazilian Portuguese translation
(cherry picked from commit 0103bbf5eb6efa817e2d42643d73dd0133fdb003)

9 years agosnapshot: Implement gtk_snapshot_clips_rect()
Benjamin Otte [Thu, 17 Nov 2016 02:31:15 +0000 (03:31 +0100)]
snapshot: Implement gtk_snapshot_clips_rect()

And use this to cull widgets and gadgets that are completely outside the
clip region.

A potential optimization is to apply this clip region to cairo contexts
created with gtk_snapshot_append_cairo_node(), but for that we'd need to
apply the inverse matrix to the clip region, and that causes rounding
errors.

Plus, I hope that cairo drawing becomes exceedingly rare so it won't be
used for the whole widget factory like today (which might also explain
why no culling happens in the widget factory outside the header bar.

9 years agosnapshot: Pass the clip region to the snapshot
Benjamin Otte [Thu, 17 Nov 2016 01:14:10 +0000 (02:14 +0100)]
snapshot: Pass the clip region to the snapshot

9 years agosnapshot: Add GtkSnapshotState
Benjamin Otte [Thu, 17 Nov 2016 00:55:26 +0000 (01:55 +0100)]
snapshot: Add GtkSnapshotState

Essentially copies cairo_gstate_t.

This is in preparation for attaching more information to the snapshot.

9 years agosnapshot: Fix graphene misunderstandings
Benjamin Otte [Thu, 17 Nov 2016 00:05:15 +0000 (01:05 +0100)]
snapshot: Fix graphene misunderstandings

The equivalent to cairo_matrix_multiply (a, b, c) is
graphene_matrix_multiply (c, b, a).

graphene_matrix_multiply (a, b, c) may not be called with b and c being
the same matrix.

9 years agosnapshot: Add infrastructure to snapshot CSS images
Benjamin Otte [Wed, 16 Nov 2016 19:51:53 +0000 (20:51 +0100)]
snapshot: Add infrastructure to snapshot CSS images

Use this infrastructure to render builtin images. Which means from now
on, GtkCheckbutton, GtkSpinner and a few others use snapshots.

9 years agorenderbackground: Remove unused functions
Benjamin Otte [Wed, 16 Nov 2016 18:31:47 +0000 (19:31 +0100)]
renderbackground: Remove unused functions

9 years agoAPI: Remove everything relating to "grip"
Benjamin Otte [Wed, 16 Nov 2016 18:27:43 +0000 (19:27 +0100)]
API: Remove everything relating to "grip"

Grips have long been unused in GTK, so remove all support for them.
This removes the GTK_STYLE_CLASS_GRIP and the special
gtk_render_handle() code for drawing those grips.

9 years agoAPI: Remove gtk_render_extension()
Benjamin Otte [Wed, 16 Nov 2016 17:36:10 +0000 (18:36 +0100)]
API: Remove gtk_render_extension()

This is long-gone drawing API.

9 years agogsktexture: Allow attaching render data to textures
Benjamin Otte [Wed, 16 Nov 2016 04:37:20 +0000 (05:37 +0100)]
gsktexture: Allow attaching render data to textures

This allows renderers (or anyone really) to attach "render data" to
textures. Only the first render data sticks.

You can gsk_texture_set_render_data() with the key you will use to
look the data up again, and if no data has been set yet, yours will be
set.

You can retrieve this data via gsk_texture_get_render_data() later on.
If your data has been cleared, NULL will be returned.

When gsk_texture_clear_render_data() is called (which the texture will
call when it is finalized), your destory notify will be called and you
have to release your render data.

The GL driver uses this to attach texture ids to GskTextures.

9 years agogsk: Rework GskTexture
Benjamin Otte [Wed, 16 Nov 2016 03:14:32 +0000 (04:14 +0100)]
gsk: Rework GskTexture

We do no longer bind textures to a renderer, instead they are a way for
applications to provide texture data.

For now, that's it. We've reverted to uploading it from scratch every
frame.

9 years agoUpdate Polish translation
Piotr Drąg [Wed, 16 Nov 2016 12:08:19 +0000 (13:08 +0100)]
Update Polish translation

9 years agoUpdate Polish translation
Piotr Drąg [Wed, 16 Nov 2016 10:43:23 +0000 (11:43 +0100)]
Update Polish translation

9 years agocontainer: ensure we only append a single node
Benjamin Otte [Tue, 15 Nov 2016 21:39:26 +0000 (22:39 +0100)]
container: ensure we only append a single node

The snapshot vfuncs must only append at most a single node,
otherwise things are going to break if the widget is the root node.

Unfortunately there is no code that can check this in a generic fashion,
so we'll have to debug this on a case-by-case basis.

9 years agosnapshot: push/pop mismatch is critical
Benjamin Otte [Tue, 15 Nov 2016 21:39:05 +0000 (22:39 +0100)]
snapshot: push/pop mismatch is critical

This is broken code that needs to be fixed right now.

9 years agowidget: Remove get_render_node() vfunc
Benjamin Otte [Tue, 15 Nov 2016 16:45:25 +0000 (17:45 +0100)]
widget: Remove get_render_node() vfunc

9 years agosnapshot: Convert inspector's RenderNodeView
Benjamin Otte [Tue, 15 Nov 2016 16:45:08 +0000 (17:45 +0100)]
snapshot: Convert inspector's RenderNodeView

9 years agocontainer: Remove get_render_node() support API
Benjamin Otte [Tue, 15 Nov 2016 16:31:24 +0000 (17:31 +0100)]
container: Remove get_render_node() support API

It's unused now.

9 years agosnapshot: Convert GtkPopover
Benjamin Otte [Tue, 15 Nov 2016 16:28:34 +0000 (17:28 +0100)]
snapshot: Convert GtkPopover

9 years agogadget: Remove gtk_css_gadget_get_render_node()
Benjamin Otte [Tue, 15 Nov 2016 15:56:37 +0000 (16:56 +0100)]
gadget: Remove gtk_css_gadget_get_render_node()

It's unused now that we can snapshot.

9 years agosnapshot: Convert GtkIcon
Benjamin Otte [Tue, 15 Nov 2016 15:39:07 +0000 (16:39 +0100)]
snapshot: Convert GtkIcon

9 years agosnapshot: Convert GtkExpander
Benjamin Otte [Tue, 15 Nov 2016 15:38:20 +0000 (16:38 +0100)]
snapshot: Convert GtkExpander

9 years agoRevert "GtkFrame: Convert to indirect rendering"
Benjamin Otte [Tue, 15 Nov 2016 15:32:30 +0000 (16:32 +0100)]
Revert "GtkFrame: Convert to indirect rendering"

This reverts commit a0b2b3745f697b91d9e91c3f10b0b3b4627a33d8.

Frames cannot be rendered by GSK yet, because they do clipping.

9 years agosnapshot: Convert GtkSeparator
Benjamin Otte [Tue, 15 Nov 2016 15:21:14 +0000 (16:21 +0100)]
snapshot: Convert GtkSeparator

9 years agoRevert "Covert GtkOverlay to indirect rendering"
Benjamin Otte [Tue, 15 Nov 2016 15:20:18 +0000 (16:20 +0100)]
Revert "Covert GtkOverlay to indirect rendering"

This reverts commit fd4a1cdad60fd291abd59dd5b13905430a674d99.

GtkOverlay uses clipping and render nodes can't clip yet.

9 years agosnapshot: convert GtkListBox
Benjamin Otte [Tue, 15 Nov 2016 15:19:21 +0000 (16:19 +0100)]
snapshot: convert GtkListBox

9 years agosnapshot: Convert GtkFlowBox
Benjamin Otte [Tue, 15 Nov 2016 15:11:19 +0000 (16:11 +0100)]
snapshot: Convert GtkFlowBox

9 years agoRevert "paned: Convert to indirect rendering"
Benjamin Otte [Tue, 15 Nov 2016 06:29:38 +0000 (07:29 +0100)]
Revert "paned: Convert to indirect rendering"

This reverts commit ba9193fc813932a3575210e42efbcf78056e07cc.

Paneds can do indirect rendering yet as we need clipping support first.

9 years agosnapshot: Convert GtkSpinner
Benjamin Otte [Tue, 15 Nov 2016 06:25:13 +0000 (07:25 +0100)]
snapshot: Convert GtkSpinner

9 years agosnapshot: Convert box gadget
Benjamin Otte [Tue, 15 Nov 2016 06:06:57 +0000 (07:06 +0100)]
snapshot: Convert box gadget

Makes spinbuttons have text again!

9 years agogsk: Allow creating cairo contexts for 0x0 nodes
Benjamin Otte [Tue, 15 Nov 2016 06:01:27 +0000 (07:01 +0100)]
gsk: Allow creating cairo contexts for 0x0 nodes

This happens in regular code paths for example when trying to render the
empty text string. We don't want to store a surface on the render
node in such a case (so actual rendering isn't slowed down), but we do
want to return a working cairo context that is not in an error state
(so the cairo rendering can continue without error messages).

9 years agowindow: Unrealize renderer last
Benjamin Otte [Tue, 15 Nov 2016 05:43:47 +0000 (06:43 +0100)]
window: Unrealize renderer last

We want to unrealize the renderer only after all widgets have been
unrealized. Otherwise, the widgets cannot release rendering resources
like textures.

9 years agorendernode: Unref texture on finalize
Benjamin Otte [Tue, 15 Nov 2016 05:43:28 +0000 (06:43 +0100)]
rendernode: Unref texture on finalize

Leaking textures is no fun.

9 years agoimage: Invalidate icon helper when unrealizing
Benjamin Otte [Tue, 15 Nov 2016 05:36:34 +0000 (06:36 +0100)]
image: Invalidate icon helper when unrealizing

This frees up any cached surfaces and textures in the iconhelper,
ensuring that the renderer can release its texture data.

9 years agosnapshot: Convert GtkImage and GtkIconHelper
Benjamin Otte [Tue, 15 Nov 2016 05:19:16 +0000 (06:19 +0100)]
snapshot: Convert GtkImage and GtkIconHelper

Adds a bunch of new APIs to render textures with theming.

FIXME: Cannot draw shadows for textures.

9 years agosnapshot: Port GtkHeaderBar
Benjamin Otte [Tue, 15 Nov 2016 03:20:40 +0000 (04:20 +0100)]
snapshot: Port GtkHeaderBar